//*************************************************************************************
//* 作    者： 邹杭特
//* 创建时间： 2021-10-21 02:41:46
//* 描    述：  

//* ************************************************************************************
using UnityEngine;

[CreateAssetMenu]
public partial class GameConfig : ScriptableObject
{
    public int bundleVersionCode;
    public bool debug_show_gui;
    public bool debug_level_open;
    public bool debug_ignore_login;

    [Header("[网络]")]
    public NetInfo netInfo;
    [Header("[语音ID]")]
    public TalkId talkId;
    [Header("[音效ID]")]
    public AudioId audioId;
    [Header("[特效ID]")]
    public EffectId effectId;
    [Header("[数据ID]")]
    public UserDataId userDataId;
    [Header("[层级ID]")]
    public LayerId layerId;

    [System.Serializable]
    public partial class NetInfo { }
    [System.Serializable]
    public partial class TalkId { }
    [System.Serializable]
    public partial class AudioId { }
    [System.Serializable]
    public partial class EffectId { }
    [System.Serializable]
    public partial class UserDataId { }
    [System.Serializable]
    public partial class LayerId { }

    public static string GetVersionText(bool versionCode)
    {
        if (versionCode)
            return Application.version + "." + Instance.bundleVersionCode;
        return Application.version;
    }
    protected static GameConfig m_instance;
    public static GameConfig Instance
    {
        get
        {
            m_instance = Resources.Load<GameConfig>("GameConfig");
            return m_instance;
        }
    }
}
